import Vue from 'vue'
import request from '@/itsoftUI/utils/request'
import qs from "qs";
const baseUrl = Vue.prototype.$itsoftUI.config.serviceUrl + "/office"
//项目字典
const apiProjectDictionary = {
    List: function (item) {
        const data = {
            item
        }
        return request({
            url: baseUrl + '/houseDataType/list',
            method: 'post',
            data: qs.stringify(data)
        })
    },

    dicList: function (enablePaging,search,order,sort) {
        const data = {
            enablePaging,
            search,
            order,
            sort
        }
        return request({
            url: baseUrl + '/houseDataTypeDetail/list',
            method: 'post',
            data: qs.stringify(data)
        })
    },

    DelRight: function (ids) {
        const data = {
            ids
        }
        return request({
            url: baseUrl + "/houseDataTypeDetail/delete",
            method: "post",
            data: qs.stringify(data)
        });
    },

    saveRight: function (data) {
        const config = {
            headers: {
                'Content-Type': 'application/json;charset=utf-8'
            },
        }
        return request.post(baseUrl + "/houseDataTypeDetail/save", data, config)
    },

    GetRight: function (id) {
        const data = {
            id
        };
        return request({
            url: baseUrl + "/houseDataTypeDetail/get",
            method: "post",
            data: qs.stringify(data)
        });
    },

    getListByCode: function (code) {
        const data = {
            code
        };
        return request({
            url: baseUrl + "/houseDataType/getListByCode",
            method: "post",
            data: qs.stringify(data)
        });
    },




}
export {apiProjectDictionary}
